#!/usr/bin/perl
#
use strict;
my $var = $ARGV[0];

if ( $var eq "" ) {
  print("Usage: progje arg
  root = generate root.
  10 = generate tree for 10 range (creating b classes).\n");
} elsif ( $var eq "root") {
  foreach my $entry (0 .. 255 ) {
    print("$entry.in-addr.arpa $entry.0.0.0 $entry.255.255.255 3\n");
  }
} else {
  foreach my $entry (0 .. 255 ) {
    print("$entry.$var.in-addr.arpa $var.$entry.0.0 $var.$entry.255.255 2\n");
  }
}
